<?php /*a:1:{s:41:"/www/wwwroot/cs/app/api/view/mp/edit.html";i:1629077431;}*/ ?>
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>layui</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <link rel="stylesheet" href="/static/layuimini/lib/layui-v2.6.3/css/layui.css" media="all">
    <link rel="stylesheet" href="/static/layuimini/css/public.css" media="all">
</head>
<body>
<div class="layuimini-container">
    <div class="layuimini-main">
<form class="layui-form layui-form-pane" action="">
    <div class="layui-form-item">
    <label class="layui-form-label">appid</label>
    <div class="layui-input-inline">
      <input type="text" name="appid" lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input">
    </div>
  </div>
<div class="layui-form-item">
    <label class="layui-form-label">appsecret</label>
    <div class="layui-input-inline">
      <input type="text" name="appsecret" lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input">
    </div>
  </div>
<div class="layui-form-item">
    <label class="layui-form-label">token</label>
    <div class="layui-input-inline">
      <input type="text" name="token" lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input">
    </div>
  </div>
<div class="layui-form-item">
    <div class="layui-input-block">
      <button type="submit" class="layui-btn" lay-submit="" lay-filter="demo1">立即提交</button>
      <button type="reset" class="layui-btn layui-btn-primary">重置</button>
    </div>
  </div>

</form>
    </div>
</div>
<script src="/static/layuimini/lib/layui-v2.6.3/layui.js" charset="utf-8"></script>

<script>
    layui.use(['form', 'util', 'layer', 'table'], function(){
        var table = layui.table;
        var layer= layui.layer;
        var form = layui.form;
        var $ = layui.jquery;
  
        //监听提交
        form.on('submit(demo1)', function(data){
            $.ajax({
                type: "post",
                url: "<?php echo url('edit'); ?>?id=",
                data:data.field,
                dataType: "json",
                success:function(data){
                    if (data.code == 1) {
                        layer.msg(data.msg); 
                    } else {
                        layer.msg(data.msg);
                    }
                }
               
          
          
      });
      
        });



        
    });
</script>
</body>

</html>